package com.jshcbd.modules.asset.entity;

import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.jshcbd.framework.poi.excel.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * @author zhoucd
 * @date
 * @description
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel( description = "资产分类表")
@TableName("classes")
public class AssetClassesEntity implements Serializable {
    private static final long serialVersionUID = 1L;

    private String id;

    @ApiModelProperty(value = "分类编码")
    @Excel(name = "分类代码")
    private String code;

    @ApiModelProperty(value = "资产大类(1:土地/2:房屋及构筑物/3:通用设备/4:车辆/5:专用设备/6:文物及陈列品/7:图书档案/8:家具用具及装具)")
    @Excel(name = "资产大类",replace = {"土地_1","房屋及构筑物_2","通用设备_3","车辆_4"
            ,"专用设备_5","文物及陈列品_6","图书档案_7","家具用具及装具_8"})
    private Integer classes;

    @ApiModelProperty(value = "分类名称")
    @Excel(name = "分类名称")
    private String typeName;


    @ApiModelProperty(value = "备注")
    @Excel(name = "备注")
    private String note;

    @ApiModelProperty(value = "折旧总月数")
    @Excel(name = "折旧月数")
    private Integer depreciationMonth;


    /**
     * 删除状态（0，正常，1已删除）
     */
    @TableLogic
    private String delFlag;

    /**
     * 更新人
     */
    @ApiModelProperty(value = "更新人")
    private String updateBy;
    /**
     * 更新时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "更新时间")
    private Date updateTime;
    /**
     * 创建人
     */
    @ApiModelProperty(value = "创建人")
    private String createBy;
    /**
     * 创建时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "创建时间")
    private Date createTime;


}
